package com.ruoyi.personnel.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.personnel.mapper.ErpAttendanceRecordMapper;
import com.ruoyi.personnel.domain.ErpAttendanceRecord;
import com.ruoyi.personnel.service.IErpAttendanceRecordService;

/**
 * 考勤记录Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-07-26
 */
@Service
public class ErpAttendanceRecordServiceImpl implements IErpAttendanceRecordService 
{
    @Autowired
    private ErpAttendanceRecordMapper erpAttendanceRecordMapper;

    /**
     * 查询考勤记录
     * 
     * @param id 考勤记录主键
     * @return 考勤记录
     */
    @Override
    public ErpAttendanceRecord selectErpAttendanceRecordById(Long id)
    {
        return erpAttendanceRecordMapper.selectErpAttendanceRecordById(id);
    }

    /**
     * 查询考勤记录列表
     * 
     * @param erpAttendanceRecord 考勤记录
     * @return 考勤记录
     */
    @Override
    public List<ErpAttendanceRecord> selectErpAttendanceRecordList(ErpAttendanceRecord erpAttendanceRecord)
    {
        return erpAttendanceRecordMapper.selectErpAttendanceRecordList(erpAttendanceRecord);
    }

    /**
     * 新增考勤记录
     * 
     * @param erpAttendanceRecord 考勤记录
     * @return 结果
     */
    @Override
    public int insertErpAttendanceRecord(ErpAttendanceRecord erpAttendanceRecord)
    {
        return erpAttendanceRecordMapper.insertErpAttendanceRecord(erpAttendanceRecord);
    }

    /**
     * 修改考勤记录
     * 
     * @param erpAttendanceRecord 考勤记录
     * @return 结果
     */
    @Override
    public int updateErpAttendanceRecord(ErpAttendanceRecord erpAttendanceRecord)
    {
        return erpAttendanceRecordMapper.updateErpAttendanceRecord(erpAttendanceRecord);
    }

    /**
     * 批量删除考勤记录
     * 
     * @param ids 需要删除的考勤记录主键
     * @return 结果
     */
    @Override
    public int deleteErpAttendanceRecordByIds(Long[] ids)
    {
        return erpAttendanceRecordMapper.deleteErpAttendanceRecordByIds(ids);
    }

    /**
     * 删除考勤记录信息
     * 
     * @param id 考勤记录主键
     * @return 结果
     */
    @Override
    public int deleteErpAttendanceRecordById(Long id)
    {
        return erpAttendanceRecordMapper.deleteErpAttendanceRecordById(id);
    }
}
